#include "aboutsoftware.h"
#include "ui_aboutsoftware.h"

AboutSoftware::AboutSoftware(QWidget *parent) :
    QDialog(parent),
    ui(new Ui::AboutSoftware)
{
    ui->setupUi(this);
    this->setWindowFlags(Qt::CustomizeWindowHint|Qt::WindowCloseButtonHint);

    /* 初始化 */
    configFileService = new ConfigFileService();

    /* 获取配置文件软件信息 */
    QString configSoftwareInfo = configFileService->getSoftwareInfo();
    configSoftwareInfo = configSoftwareInfo.trimmed(); // 去掉字符串前后空格
    ui->functionDescription->setText(configSoftwareInfo);

    /* 关闭按钮 */
    connect(ui->close, &QPushButton::clicked, this, [=](){
        this->close();
    });

}

AboutSoftware::~AboutSoftware()
{
    delete ui;
}
